﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;

namespace MVC0721.Models
{
    /// <summary>
    /// 来宾响应来，用于来宾提交表单
    /// </summary>
    public class GuestResponse
    {
        [Required(ErrorMessage ="请输入用户名")]
        public string Name { get; set; }

        [Required(ErrorMessage ="请输入你的的电子邮箱地址")]
        [RegularExpression(".+\\@.+\\..+",ErrorMessage ="请输入合法的电子邮箱址，如web@hx008.com")]
        public string Email { get; set; }
        
        [Required(ErrorMessage ="请输入你的电话号码")]
        public string Phone { get; set; }

        [Required(ErrorMessage ="请选择你的参与加意向")]
        public bool? WillAttend { get; set; }
    }
}